package com.example.Wisdompark.service;

import com.example.Wisdompark.dao.EntryOrderMapper;
import com.example.Wisdompark.pojo.Current_Cargo;
import com.example.Wisdompark.pojo.Entry_Order;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public class EntryOrderImpl implements EntryOrderService{
    @Autowired
    private EntryOrderMapper entryOrderMapper;

    @Override
    public List<Entry_Order> queryAllOrder() {
        return entryOrderMapper.queryAllOrder();
    }

    @Override
    public int insertAOrder(Entry_Order entryorder) {
        return entryOrderMapper.insertAOrder(entryorder);
    }

    @Override
    public int delAOrder(String order_num) {
       return entryOrderMapper.delAOrder(order_num);
    }

    @Override
    public int updateAOrder(Entry_Order entryorder) {
        return entryOrderMapper.updateAOrder(entryorder);
    }

    @Override
    public Entry_Order queryByOrderNum(String order_num) {
        return entryOrderMapper.queryByOrderNum(order_num);
    }

    @Override
    public List<Entry_Order> queryOrderByState(Integer state) {
        return entryOrderMapper.queryOrderByState(state);
    }

    @Override
    public int updateOrderState(String order_num, int state) {
        return entryOrderMapper.updateOrderState(order_num,state);


    }
}
